﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="lc_modifypwd.aspx.cs" Inherits="HFWebApp.lawyeruser.lc_modifypwd" %>
<%@ Register src="../Control/top.ascx" tagname="top" tagprefix="uc1" %>
<%@ Register src="../Control/end.ascx" tagname="end" tagprefix="uc2" %>
<%@ Register src="c_LeftMenu.ascx" tagname="c_LeftMenu" tagprefix="uc3" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />
<title>用户管理中心_红法网</title>
<link href="<%=this.getDemain %>/Style/Style.css" rel="stylesheet" type="text/css" />
<link href="<%=this.getDemain %>/Style/CenterStyle.css" rel="stylesheet" type="text/css" />
<link href="<%=this.getDemain %>/CSS.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<%=this.getDemain %>/Scripts/jquery-1.8.0.min.js"></script>
<script type="text/javascript">
    function SendModifyPWD() {
        var oldPwd = $("#oldPwd");
        if (oldPwd.val() == "") {
            alert('请填写当前密码');
            oldPwd.focus();
            return false;
        }
        var newpwd = $("#newpwd");
        if (newpwd.val() == "") {
            alert('请填写要修改的密码');
            newpwd.focus();
            return false;
        }
        var newpwd2 = $("#newpwd2");
        if (newpwd2.val() == "") {
            alert('请填写确认密码');
            newpwd2.focus();
            return false;
        }
        if (newpwd.val() != newpwd2.val()) {
            alert('两次输入的密码不一致');
            newpwd2.focus();
            return false;
        }
        $.getJSON(
            "/AjaxSource/LawyerModify.ashx",
            {
                action: "1",
                oldpwd: oldPwd.val(),
                newpwd: newpwd.val(),
                rand: Math.floor(Math.random() * 10000).toString()
            },
            function (jsonData) {
                alert(jsonData.Message);
                if (jsonData.isTrue) {
                    oldPwd.val("");
                    newpwd.val("");
                    newpwd2.val("");
                }
            }
        );
        return false;
    }
</script>
</head>

<body>
<uc1:top ID="top1" MenuClassID="1" focusLink1="focusLink" runat="server" />
<div id="c_BodyBox">
    <div class="c_LeftMenu">
        <uc3:c_LeftMenu ID="c_LeftMenu1" runat="server" />
    </div>
    <div class="c_RightContent">
        <h3>修改密码</h3>
        <div class="c_MessageBox">
            <ul>
            <form id="modifyForm" onsubmit="return SendModifyPWD();">
                <li>
                    <div class="c_MB_Left">当前密码</div>
                    <div class="c_MB_Mid"><input name="oldPwd" type="password" id="oldPwd" value="" size="32" /></div>
                    <div class="c_MB_Right"></div>
                </li>
                <li>
                    <div class="c_MB_Left">新密码</div>
                    <div class="c_MB_Mid"><input name="newpwd" type="password" id="newpwd" value="" size="32" /></div>
                    <div class="c_MB_Right"></div>
                </li>
                <li>
                    <div class="c_MB_Left">确认新密码</div>
                    <div class="c_MB_Mid"><input name="newpwd2" type="password" id="newpwd2" value="" size="32" /></div>
                    <div class="c_MB_Right"></div>
                </li>
                <li>
                    <div class="c_MB_Left"></div>
                    <div class="c_MB_Mid"><input id="Button1" type="submit" value="保存" /></div>
                    <div class="c_MB_Right"></div>
                </li>
            </form>
            </ul>
        </div>
    </div>
</div>
<uc2:end ID="end1" runat="server" />
</body>
</html>

